﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using MEF_Test.Bricks;
using MEF_Test.Bricks.TemplateProvider;
using MEF_Test.Contracts;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Moq;

namespace ModuleOne.Test
{
    /// <summary>
    /// Summary description for DiskMediaProviderTest
    /// </summary>
    [TestClass]
    public class DiskMediaBrowsingProviderTest
    {


        [TestMethod]
        public void TestDiskMediaBrowsingProviderCanGoToDrivesList()
        {
            // ceremony 1
            IDiskBrowserNodeViewModelFactory browserNodeViewModelFactory = new Mock<IDiskBrowserNodeViewModelFactory>().Object;
            ITemplateProvider templateProvider = new Mock<ITemplateProvider>().Object;
            IMediaHandlerFactoryProvider mediaHandlerFactory = new Mock<IMediaHandlerFactoryProvider>().Object;
            IDiskFileHandlerFactory fileHandlerFactory = new Mock<IDiskFileHandlerFactory>().Object;


            // Ceremony 2
            Mock<IBrowserNodeViewModel<IDiskFileHandler>> defaultNodeMock = new Mock<IBrowserNodeViewModel<IDiskFileHandler>>();
            IBrowserNodeViewModel<IDiskFileHandler> defaultNode = defaultNodeMock.Object;
            defaultNodeMock.Setup(o => o.FileHandler.Path).Returns("diskslist://root");
            DiskMediaBrowsingProvider browsingProvider = new DiskMediaBrowsingProvider(defaultNode, fileHandlerFactory, mediaHandlerFactory, templateProvider, browserNodeViewModelFactory);
        }
    }
}
